package FirstHomeworks;

import org.testng.Assert;
import org.testng.annotations.DataProvider;
import org.testng.annotations.Parameters;
import org.testng.annotations.Test;


/**
 * Created with IntelliJ IDEA.
 * User: admin
 * Date: 05.03.14
 * Time: 20:55
 * To change this template use File | Settings | File Templates.
 */
public class Lesson2 {

    @DataProvider(name = "test1")
    public Object[][] provideData() {

        return new Object[][] {
                new Object[]{new int []{1, 3, 5, 9}},
                //new Object[]{new int []{2, 1, 7, 4, 3 }},
        };
    }

    @Test(dataProvider = "test1")
    public void testingTest2(int[] numbers)
    {
        for (int j = 0; j < numbers.length - 1; j++)
        {
            Assert.assertTrue(numbers[j] <= numbers[j + 1]);
        }
    }
}


